// 库存管理接口
import request from "@/common/request.js";
const api = {
  client: "/client/",
  client_classify: "/client_classify",
  client_source: "/client_source/",
  staff: "/staff/",
};

const clIndexApi = {
  get_staff(params) {
    return request({
      url: api.staff,
      method: "get",
      params,
    });
  },

  get_client(params) {
    return request({
      url: api.client,
      method: "get",
      params,
    });
  },

  get_client_classify(params) {
    return request({
      url: api.client_classify,
      method: "get",
      params,
    });
  },

  get_client_source(params) {
    return request({
      url: api.client_source,
      method: "get",
      params,
    });
  },

  client_detail(id) {
    return request({
      url: api.client + id,
      method: "get",
    });
  },

  post_client(data) {
    return request({
      url: api.client,
      method: "post",
      data,
    });
  },

  patch_client(data, id) {
    return request({
      url: api.client + id + "/",
      method: "patch",
      data,
    });
  },

  delete_client(id) {
    return request({
      url: api.client + id + "/",
      method: "delete",
    });
  },
};
export default clIndexApi
